import detail from '@/views/detail/index.vue'
import fl from '@/views/fl/index.vue'
import home from '@/views/home/index.vue'
import login from '@/views/login/index.vue'
import my from '@/views/my/index.vue'
import shop from '@/views/shop/index.vue'
import { createRouter, createWebHistory } from 'vue-router'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/home',
      name: 'home',
      component: home,
    },
    {
      path: '/login',
      name: 'login',
      component: login,
    },
    {
      path: '/fl',
      name: 'fl',
      component: fl,
    },
    {
      path: '/my',
      name: 'my',
      component: my,
    },
    {
      path: '/shop',
      name: 'shop',
      component: shop,
    },
    {
      path: '/detail/:id',
      name: 'detail',
      component: detail,
    },
  ],
})

export default router
